//
//  MTHomeVC.m
//  met
//
//  Created by 李晓俊 on 2019/4/29.
//  Copyright © 2019 李晓俊. All rights reserved.
//

#import "MTHomeVC.h"
@interface MTHomeVC ()

@end

@implementation MTHomeVC

- (void)viewDidLoad {
    [super viewDidLoad];
    // Do any additional setup after loading the view.
     [self wr_setNavBarBackgroundAlpha:0];

    self.view.backgroundColor = KBackColor;

}
- (void)CreateNav {
    
}
- (void)viewWillAppear:(BOOL)animated{
    //设置导航栏背景图片为一个空的image，这样就透明了
    [self.navigationController.navigationBar setBackgroundImage:[[UIImage alloc] init] forBarMetrics:UIBarMetricsDefault];

    //去掉透明后导航栏下边的黑边
    [self.navigationController.navigationBar setShadowImage:[[UIImage alloc] init]];
}

- (void)viewWillDisappear:(BOOL)animated{
    //如果不想让其他页面的导航栏变为透明 需要重置
    [self.navigationController.navigationBar setBackgroundImage:nil forBarMetrics:UIBarMetricsDefault];
    [self.navigationController.navigationBar setShadowImage:nil];
}
@end
